package com.spzx.alex008cache20250513.mapper;

import com.spzx.alex008cache20250513.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface UserMapper {
    
    @Select("SELECT * FROM t_user WHERE id = #{id}")
    User selectById(Long id);
    
    @Update("UPDATE t_user SET username=#{username}, age=#{age}, email=#{email} WHERE id=#{id}")
    void updateById(User user);
}